import request from '/src/axios.js';
import {baseUrl} from "../../config/env";

export const sysLogApi = {
  getPage: (current, size, params) => request({
    // api-log/sysLog?sortCol=timestamp&isHighlighter=true&page=1&limit=10&queryStr=appName%3Auser-center
    url: baseUrl + '/api-log/sysLog',
    method: 'get',
    params: {
      isHighlighter: true,
      sortCol: "timestamp",
      page: current,
      limit: size,
      queryStr: "" //queryStr=appName:user-center
    }
  }),
  create: (row) => request({
    url: baseUrl + '/api-user/tenant/create',
    method: 'post',
    data: row
  }),

  remove: (ids) => request({
    url: baseUrl + '/api-user/tenant/remove',
    method: 'post',
    params: {
      ids,
    }
  }),
  update: (row) => request({
    url: baseUrl + '/api-user/tenant/update',
    method: 'post',
    data: row
  }),

  getDetail: (id) => request({
    url: baseUrl + '/api-user/tenant/' + id,
    method: 'get',
    // data: row
  }),
  getByTenantId: () => {
    return request({
      url: baseUrl + '/api-user/tenant/getByTenantId',
      method: 'get',
      // data: row
    })
  }
}

